Integrand size = 42, antiderivative size = 164 \[ \int \cos ^4(c+d x) (a+a \sec (c+d x))^{5/2} \left (B \sec (c+d x)+C \sec ^2(c+d x)\right ) \, dx=\frac {a^{5/2} (25 B+38 C) \arctan \left (\frac {\sqrt {a} \tan (c+d x)}{\sqrt {a+a \sec (c+d x)}}\right )}{8 d}+\frac {a^3 (49 B+54 C) \sin (c+d x)}{24 d \sqrt {a+a \sec (c+d x)}}+\frac {a^2 (3 B+2 C) \cos (c+d x) \sqrt {a+a \sec (c+d x)} \sin (c+d x)}{4 d}+\frac {a B \cos ^2(c+d x) (a+a \sec (c+d x))^{3/2} \sin (c+d x)}{3 d} \]
[Out]
Time = 0.70 (sec) , antiderivative size = 164, normalized size of antiderivative = 1.00, number of steps used = 6, number of rules used = 5, \(\frac {\text {number of rules}}{\text {integrand size}}\) = 0.119, Rules used = {4157, 4102, 4100, 3859, 209} \[ \int \cos ^4(c+d x) (a+a \sec (c+d x))^{5/2} \left (B \sec (c+d x)+C \sec ^2(c+d x)\right ) \, dx=\frac {a^{5/2} (25 B+38 C) \arctan \left (\frac {\sqrt {a} \tan (c+d x)}{\sqrt {a \sec (c+d x)+a}}\right )}{8 d}+\frac {a^3 (49 B+54 C) \sin (c+d x)}{24 d \sqrt {a \sec (c+d x)+a}}+\frac {a^2 (3 B+2 C) \sin (c+d x) \cos (c+d x) \sqrt {a \sec (c+d x)+a}}{4 d}+\frac {a B \sin (c+d x) \cos ^2(c+d x) (a \sec (c+d x)+a)^{3/2}}{3 d} \]
[In]
[Out]
Rule 209
Rule 3859
Rule 4100
Rule 4102
Rule 4157
Rubi steps \begin{align*} \text {integral}& = \int \cos ^3(c+d x) (a+a \sec (c+d x))^{5/2} (B+C \sec (c+d x)) \, dx \\ & = \frac {a B \cos ^2(c+d x) (a+a \sec (c+d x))^{3/2} \sin (c+d x)}{3 d}+\frac {1}{3} \int \cos ^2(c+d x) (a+a \sec (c+d x))^{3/2} \left (\frac {3}{2} a (3 B+2 C)+\frac {1}{2} a (B+6 C) \sec (c+d x)\right ) \, dx \\ & = \frac {a^2 (3 B+2 C) \cos (c+d x) \sqrt {a+a \sec (c+d x)} \sin (c+d x)}{4 d}+\frac {a B \cos ^2(c+d x) (a+a \sec (c+d x))^{3/2} \sin (c+d x)}{3 d}+\frac {1}{6} \int \cos (c+d x) \sqrt {a+a \sec (c+d x)} \left (\frac {1}{4} a^2 (49 B+54 C)+\frac {1}{4} a^2 (13 B+30 C) \sec (c+d x)\right ) \, dx \\ & = \frac {a^3 (49 B+54 C) \sin (c+d x)}{24 d \sqrt {a+a \sec (c+d x)}}+\frac {a^2 (3 B+2 C) \cos (c+d x) \sqrt {a+a \sec (c+d x)} \sin (c+d x)}{4 d}+\frac {a B \cos ^2(c+d x) (a+a \sec (c+d x))^{3/2} \sin (c+d x)}{3 d}+\frac {1}{16} \left (a^2 (25 B+38 C)\right ) \int \sqrt {a+a \sec (c+d x)} \, dx \\ & = \frac {a^3 (49 B+54 C) \sin (c+d x)}{24 d \sqrt {a+a \sec (c+d x)}}+\frac {a^2 (3 B+2 C) \cos (c+d x) \sqrt {a+a \sec (c+d x)} \sin (c+d x)}{4 d}+\frac {a B \cos ^2(c+d x) (a+a \sec (c+d x))^{3/2} \sin (c+d x)}{3 d}-\frac {\left (a^3 (25 B+38 C)\right ) \text {Subst}\left (\int \frac {1}{a+x^2} \, dx,x,-\frac {a \tan (c+d x)}{\sqrt {a+a \sec (c+d x)}}\right )}{8 d} \\ & = \frac {a^{5/2} (25 B+38 C) \arctan \left (\frac {\sqrt {a} \tan (c+d x)}{\sqrt {a+a \sec (c+d x)}}\right )}{8 d}+\frac {a^3 (49 B+54 C) \sin (c+d x)}{24 d \sqrt {a+a \sec (c+d x)}}+\frac {a^2 (3 B+2 C) \cos (c+d x) \sqrt {a+a \sec (c+d x)} \sin (c+d x)}{4 d}+\frac {a B \cos ^2(c+d x) (a+a \sec (c+d x))^{3/2} \sin (c+d x)}{3 d} \\ \end{align*}
Time = 3.90 (sec) , antiderivative size = 121, normalized size of antiderivative = 0.74 \[ \int \cos ^4(c+d x) (a+a \sec (c+d x))^{5/2} \left (B \sec (c+d x)+C \sec ^2(c+d x)\right ) \, dx=\frac {a^2 \left (3 (25 B+38 C) \arctan \left (\sqrt {-1+\sec (c+d x)}\right )+\cos (c+d x) (79 B+66 C+2 (17 B+6 C) \cos (c+d x)+4 B \cos (2 (c+d x))) \sqrt {-1+\sec (c+d x)}\right ) \sqrt {a (1+\sec (c+d x))} \tan \left (\frac {1}{2} (c+d x)\right )}{24 d \sqrt {-1+\sec (c+d x)}} \]
[In]
[Out]
Leaf count of result is larger than twice the leaf count of optimal. \(368\) vs. \(2(144)=288\).
Time = 196.44 (sec) , antiderivative size = 369, normalized size of antiderivative = 2.25
method | result | size |
default | \(\frac {a^{2} \left (8 B \sin \left (d x +c \right ) \cos \left (d x +c \right )^{3}+75 B \,\operatorname {arctanh}\left (\frac {\sin \left (d x +c \right )}{\left (\cos \left (d x +c \right )+1\right ) \sqrt {-\frac {\cos \left (d x +c \right )}{\cos \left (d x +c \right )+1}}}\right ) \sqrt {-\frac {\cos \left (d x +c \right )}{\cos \left (d x +c \right )+1}}\, \cos \left (d x +c \right )+34 B \sin \left (d x +c \right ) \cos \left (d x +c \right )^{2}+114 C \sqrt {-\frac {\cos \left (d x +c \right )}{\cos \left (d x +c \right )+1}}\, \operatorname {arctanh}\left (\frac {\sin \left (d x +c \right )}{\left (\cos \left (d x +c \right )+1\right ) \sqrt {-\frac {\cos \left (d x +c \right )}{\cos \left (d x +c \right )+1}}}\right ) \cos \left (d x +c \right )+12 C \cos \left (d x +c \right )^{2} \sin \left (d x +c \right )+75 B \sqrt {-\frac {\cos \left (d x +c \right )}{\cos \left (d x +c \right )+1}}\, \operatorname {arctanh}\left (\frac {\sin \left (d x +c \right )}{\left (\cos \left (d x +c \right )+1\right ) \sqrt {-\frac {\cos \left (d x +c \right )}{\cos \left (d x +c \right )+1}}}\right )+75 B \cos \left (d x +c \right ) \sin \left (d x +c \right )+114 C \sqrt {-\frac {\cos \left (d x +c \right )}{\cos \left (d x +c \right )+1}}\, \operatorname {arctanh}\left (\frac {\sin \left (d x +c \right )}{\left (\cos \left (d x +c \right )+1\right ) \sqrt {-\frac {\cos \left (d x +c \right )}{\cos \left (d x +c \right )+1}}}\right )+66 C \cos \left (d x +c \right ) \sin \left (d x +c \right )\right ) \sqrt {a \left (1+\sec \left (d x +c \right )\right )}}{24 d \left (\cos \left (d x +c \right )+1\right )}\) | \(369\) |
[In]
[Out]
none
Time = 0.31 (sec) , antiderivative size = 380, normalized size of antiderivative = 2.32 \[ \int \cos ^4(c+d x) (a+a \sec (c+d x))^{5/2} \left (B \sec (c+d x)+C \sec ^2(c+d x)\right ) \, dx=\left [\frac {3 \, {\left ({\left (25 \, B + 38 \, C\right )} a^{2} \cos \left (d x + c\right ) + {\left (25 \, B + 38 \, C\right )} a^{2}\right )} \sqrt {-a} \log \left (\frac {2 \, a \cos \left (d x + c\right )^{2} - 2 \, \sqrt {-a} \sqrt {\frac {a \cos \left (d x + c\right ) + a}{\cos \left (d x + c\right )}} \cos \left (d x + c\right ) \sin \left (d x + c\right ) + a \cos \left (d x + c\right ) - a}{\cos \left (d x + c\right ) + 1}\right ) + 2 \, {\left (8 \, B a^{2} \cos \left (d x + c\right )^{3} + 2 \, {\left (17 \, B + 6 \, C\right )} a^{2} \cos \left (d x + c\right )^{2} + 3 \, {\left (25 \, B + 22 \, C\right )} a^{2} \cos \left (d x + c\right )\right )} \sqrt {\frac {a \cos \left (d x + c\right ) + a}{\cos \left (d x + c\right )}} \sin \left (d x + c\right )}{48 \, {\left (d \cos \left (d x + c\right ) + d\right )}}, -\frac {3 \, {\left ({\left (25 \, B + 38 \, C\right )} a^{2} \cos \left (d x + c\right ) + {\left (25 \, B + 38 \, C\right )} a^{2}\right )} \sqrt {a} \arctan \left (\frac {\sqrt {\frac {a \cos \left (d x + c\right ) + a}{\cos \left (d x + c\right )}} \cos \left (d x + c\right )}{\sqrt {a} \sin \left (d x + c\right )}\right ) - {\left (8 \, B a^{2} \cos \left (d x + c\right )^{3} + 2 \, {\left (17 \, B + 6 \, C\right )} a^{2} \cos \left (d x + c\right )^{2} + 3 \, {\left (25 \, B + 22 \, C\right )} a^{2} \cos \left (d x + c\right )\right )} \sqrt {\frac {a \cos \left (d x + c\right ) + a}{\cos \left (d x + c\right )}} \sin \left (d x + c\right )}{24 \, {\left (d \cos \left (d x + c\right ) + d\right )}}\right ] \]
[In]
[Out]
Timed out. \[ \int \cos ^4(c+d x) (a+a \sec (c+d x))^{5/2} \left (B \sec (c+d x)+C \sec ^2(c+d x)\right ) \, dx=\text {Timed out} \]
[In]
[Out]
Timed out. \[ \int \cos ^4(c+d x) (a+a \sec (c+d x))^{5/2} \left (B \sec (c+d x)+C \sec ^2(c+d x)\right ) \, dx=\text {Timed out} \]
[In]
[Out]
\[ \int \cos ^4(c+d x) (a+a \sec (c+d x))^{5/2} \left (B \sec (c+d x)+C \sec ^2(c+d x)\right ) \, dx=\int { {\left (C \sec \left (d x + c\right )^{2} + B \sec \left (d x + c\right )\right )} {\left (a \sec \left (d x + c\right ) + a\right )}^{\frac {5}{2}} \cos \left (d x + c\right )^{4} \,d x } \]
[In]
[Out]
Timed out. \[ \int \cos ^4(c+d x) (a+a \sec (c+d x))^{5/2} \left (B \sec (c+d x)+C \sec ^2(c+d x)\right ) \, dx=\int {\cos \left (c+d\,x\right )}^4\,\left (\frac {B}{\cos \left (c+d\,x\right )}+\frac {C}{{\cos \left (c+d\,x\right )}^2}\right )\,{\left (a+\frac {a}{\cos \left (c+d\,x\right )}\right )}^{5/2} \,d x \]
[In]
[Out]